package com.luo.controller;


import com.luo.pojo.po.Results;
import com.luo.service.IProductTypesService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author luo
 * @since 2025-06-24
 */
@Api(tags = "商品类型管理")
@RestController
@RequestMapping("/product-types")
@RequiredArgsConstructor
@CrossOrigin("*")
public class ProductTypesController {
    private final IProductTypesService productTypesService;
    @ApiOperation("查询商品类型")
    @GetMapping
    public Results Inquire(@ApiParam("商品类型名称") @RequestParam(required = false) String keyword){
        return Results.success(productTypesService.Inquire(keyword));
    }
}
